package com.lbs.jiepiaisi.adapter;

import android.support.annotation.LayoutRes;

import android.support.annotation.Nullable;
import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;
import com.lbs.jiepiaisi.R;
import com.lbs.jiepiaisi.bean.AlarmBean;

import java.util.List;

/**
 * Created by yu on 2019-12-23 15:09.
 * Description:
 */

public class AlarmListAdapter extends BaseQuickAdapter<AlarmBean.Result.Item,BaseViewHolder> {

    public AlarmListAdapter(@LayoutRes int layoutResId, @Nullable List data) {
        super(layoutResId, data);
    }

    @Override
    protected void convert(BaseViewHolder helper, AlarmBean.Result.Item item) {
        helper.setText(R.id.tv_num, item.getEqNo())
                .setText(R.id.tv_name, item.getOwnerName())
                .setText(R.id.tv_type, item.getDicProTitle())
                .setText(R.id.tv_time, item.getAlTime())
                .addOnClickListener(R.id.ll_top);
    }

}
